<script src ="scripts/newsSet.js"></script>
<script src ="scripts/httpService.js"></script>

            <div class="pageheader">
                <h2><i class="fa fa-hand-o-up"></i> 设置消息管理 </h2>
            </div>

            <div class="contentpanel" ng-app="noticeApp" ng-controller="noticeCtrl">
                <div class="row xg-content">
                    <div class="col-xs-12">
                        <div class="btn-group">
                            <button type="button" class="btn btn-warning" ng-click="refresh()"><span class="glyphicon glyphicon-refresh"></span> 刷新</button>
                            <button type="button" class="btn btn-primary" ng-click="addNotice()"><span class="glyphicon glyphicon-pencil"></span> 添加消息</button>
                            <button type="button" class="btn btn-success" ng-click="updateNotice()"><span class="glyphicon glyphicon-send"></span> 更新消息</button>
                            <button type="button" class="btn btn-danger" ng-click="deleteNotice"><span class="glyphicon glyphicon-trash"></span> 删除消息</button>
                                                            
                        </div>
                        <table class="table table-striped table-hover">
                            <tr>
                                <th>选择</th>
                                <th>id</th>
                                <th>题目</th>                                
                                <th>日期</th>
                                <th>修改</th>
                            </tr>
                            <tr ng-repeat="news in newsset" ng-click="selectChange($index)">
                                <td><input type="checkbox" ng-model="news.checked" /> </td>                   
                                <td ng-bind="news.id"></td>
                                <td ng-bind="news.topic|limitTo:100"></td>
                                <td ng-bind="news.date"></td>
                                <td ><button type="button" class="btn">修改</button></td>
                           
                            </tr>
                            
                        </table>
                    </div>
                </div>
                
            <script type="text/ng-template" id="modifyNotice">
                 <div class='modal-content'  >
        <div class='modal-header'>
        <button type='button' class='close' data-dismiss='modal' ng-click="close()" >&times;</button>
        <h2 class='modal-title' style="padding-left:40%" id='addParkLabel'>通知</h2>
        </div>

        <div class='modal-body '>
        <form class='form-horizontal' role='form'>
        <div class="panel panel-info">
        <div class="panel-heading">
        <h3 class="panel-title">
                            通知消息
        </h3>
        </div>
        <div class="panel-body">
        <div class='form-group '>
        <div class="col-sm-2 ">
        <label class='control-label' style="float:right" >内容</label>
        </div>
        <div class='col-sm-10'>
        <textarea rows='5' class="form-control" ng-model="notice.content"></textarea>
        </select>
        </div>        
        </div>
        
        <div class='form-group '>
        <div class="col-sm-2 ">
        <label class='control-label' style="float:right">作者</label>
        </div>
        <div class='col-sm-10'>
       <input type="text" class='form-control date' ng-model="notice.owner" placeholder='填写作者信息'/>      
        </div>        
        </div>
        
         <div class='form-group '>
        <div class="col-sm-2 ">
        <label class='control-label' style="float:right">备注</label>
        </div>
        <div class='col-sm-10'>
       <input type="text" class='form-control date' ng-model="notice.other" placeholder='填写备注信息'/>      
        </div>        
        </div>
        
        </div>
        </div>
        
        <div class="alert alert-info" ng-show="loading || submitted">
            <span  ng-show='loading' > <i class="fa fa-spinner"></i></span>
            <span ng-show='submitted'>{{result}}</span>
        </div>
        
        <div class='modal-footer'>
        <button type='button' class='btn btn-default' id="modalCloseBtn" data-dismiss='modal' ng-click="close()">关闭</button>
        <button id="submitParkBtn" type='button'ng-click="submit()" class='btn btn-primary'>提交</button>
        </div>
        
        </div>
            </script>
            </div><!-- contentpanel -->         
        </div><!-- mainpanel -->
        <script src="js/xg_js.js"></script>
        <script>
            createMenu(11);
        </script>
